<?xml version="1.0" encoding="iso-8859-1"?>
<!DOCTYPE html PUBLIC "-//W3C//DTD XHTML 1.0 Transitional//EN" "http://www.w3.org/TR/xhtml1/DTD/xhtml1-transitional.dtd">
  <html xmlns="http://www.w3.org/1999/xhtml">
		<head>
			<!-- template designed by Marco Von Ballmoos -->
			<title>Docs For Class Credentials</title>
			<link rel="stylesheet" href="../media/stylesheet.css" />
			<meta http-equiv='Content-Type' content='text/html; charset=iso-8859-1'/>
		</head>
		<body>
			<div class="page-body">			
<h2 class="class-name">Interface Credentials</h2>

<a name="sec-description"></a>
<div class="info-box">
	<div class="info-box-title">Description</div>
	<div class="nav-bar">
					<span class="disabled">Description</span> |
															<a href="#sec-method-summary">Methods</a> (<a href="#sec-methods">details</a>)
						
					</div>
	<div class="info-box-body">
        		<!-- ========== Info from phpDoc block ========= -->
<p class="short-description">Base interface for all credentials that may be passed to the  <a href="../phpContentRepository/Repository.html#methodlogin">Repository::login()</a> method.</p>
<p class="description"><p>Provides a minimal standard method for authenticating against a  repository (i.e., using a user ID and password). Additional attributes may  be used by the repository to, for example, set a token that can then be  passed back and forth once authentication has been completed (thus enabling  later authorization without re-authentication). In addition, any class that  implements this interface can also, of course, add its own methods to deal  with more advanced authentication/authorization mechanisms.</p><p>PHP Notes: The Java implementation of this extends the class  Serializable.  PHP does not have a counterpart, and is not needed, as the  language provides the  <a href="http://us3.php.net/manual/en/function.serialize.php">serialize()</a>  function.</p></p>
	<ul class="tags">
				<li><span class="field">copyright:</span> Copyright &amp;copy; 2004-2005, Domain51</li>
				<li><span class="field">author:</span> PHP - Travis Swicegood &lt;<a href="mailto:travis@domain51.net">travis@domain51.net</a>&gt;</li>
			</ul>
		<p class="notes">
			Located in <a class="field" href="_Credentials_interface_php.html">/Credentials.interface.php</a> (line <span class="field">50</span>)
		</p>
		
				
		<pre></pre>
	
			</div>
</div>




	<a name="sec-method-summary"></a>
	<div class="info-box">
		<div class="info-box-title">Method Summary</span></div>
		<div class="nav-bar">
			<a href="#sec-description">Description</a> |
												<span class="disabled">Methods</span> (<a href="#sec-methods">details</a>)
		</div>
		<div class="info-box-body">			
			<div class="method-summary">
								
				<div class="method-definition">
											<span class="method-result">mixed</span>
										<a href="#getAttribute" title="details" class="method-name">getAttribute</a>
											(<span class="var-type">string</span>&nbsp;<span class="var-name">$name</span>)
									</div>
								
				<div class="method-definition">
											<span class="method-result">array</span>
										<a href="#getAttributeNames" title="details" class="method-name">getAttributeNames</a>
										()
									</div>
								
				<div class="method-definition">
											<span class="method-result">string</span>
										<a href="#getPassword" title="details" class="method-name">getPassword</a>
										()
									</div>
								
				<div class="method-definition">
											<span class="method-result">string</span>
										<a href="#getUserID" title="details" class="method-name">getUserID</a>
										()
									</div>
								
				<div class="method-definition">
											<span class="method-result">void</span>
										<a href="#removeAttribute" title="details" class="method-name">removeAttribute</a>
											(<span class="var-type">string</span>&nbsp;<span class="var-name">$name</span>)
									</div>
								
				<div class="method-definition">
											<span class="method-result">void</span>
										<a href="#setAttribute" title="details" class="method-name">setAttribute</a>
											(<span class="var-type">string</span>&nbsp;<span class="var-name">$name</span>, <span class="var-type">mixed</span>&nbsp;<span class="var-name">$value</span>)
									</div>
							</div>
		</div>
	</div>		

	
	<a name="sec-methods"></a>
	<div class="info-box">
		<div class="info-box-title">Methods</div>
		<div class="nav-bar">
			<a href="#sec-description">Description</a> |
																<a href="#sec-method-summary">Methods</a> (<span class="disabled">details</span>)
						
		</div>
		<div class="info-box-body">
			<A NAME='method_detail'></A>
<a name="methodgetAttribute" id="getAttribute"><!-- --></a>
<div class="evenrow">
	
	<div class="method-header">
		<span class="method-title">getAttribute</span> (line <span class="line-number">110</span>)
	</div> 
	
	<!-- ========== Info from phpDoc block ========= -->
<p class="short-description">Returns the value of the NAMED attribute as set by setAttribute(),  or NULL if no attribute of the given name exists.</p>
<p class="description"><p>See the PHP Note in <a href="../phpContentRepository/Credentials.html#methodsetAttribute">setAttribute()</a> for information on the  return type here.</p></p>
	<ul class="tags">
				<li><span class="field">return:</span> The value of the attribute,  or NULL if the attribute does    not exist.</li>
				<li><span class="field">access:</span> public</li>
			</ul>
	
	<div class="method-signature">
		<span class="method-result">mixed</span>
		<span class="method-name">
			getAttribute
		</span>
					(<span class="var-type">string</span>&nbsp;<span class="var-name">$name</span>)
			</div>
	
			<ul class="parameters">
					<li>
				<span class="var-type">string</span>
				<span class="var-name">$name</span><span class="var-description">: Specifies the name of the attribute</span>			</li>
				</ul>
		
		
	</div>
<a name="methodgetAttributeNames" id="getAttributeNames"><!-- --></a>
<div class="oddrow">
	
	<div class="method-header">
		<span class="method-title">getAttributeNames</span> (line <span class="line-number">123</span>)
	</div> 
	
	<!-- ========== Info from phpDoc block ========= -->
<p class="short-description">Returns the names of the attributes available to this <a href="../phpContentRepository/Credentials.html">Credentials</a>  instance.</p>
<p class="description"><p>This method returns an empty array if the credentials instance has no  attributes available to it.</p></p>
	<ul class="tags">
				<li><span class="field">return:</span> An array containing the names of the stored attributes</li>
				<li><span class="field">access:</span> public</li>
			</ul>
	
	<div class="method-signature">
		<span class="method-result">array</span>
		<span class="method-name">
			getAttributeNames
		</span>
				()
			</div>
	
		
		
	</div>
<a name="methodgetPassword" id="getPassword"><!-- --></a>
<div class="evenrow">
	
	<div class="method-header">
		<span class="method-title">getPassword</span> (line <span class="line-number">69</span>)
	</div> 
	
	<!-- ========== Info from phpDoc block ========= -->
<p class="short-description">Returns the password.</p>
<p class="description"><p>Note that this method returns a reference to the password.  It is the caller's responsibility to zero out the password information  after it is no longer needed.</p></p>
	<ul class="tags">
				<li><span class="field">access:</span> public</li>
			</ul>
	
	<div class="method-signature">
		<span class="method-result">string</span>
		<span class="method-name">
			getPassword
		</span>
				()
			</div>
	
		
		
	</div>
<a name="methodgetUserID" id="getUserID"><!-- --></a>
<div class="oddrow">
	
	<div class="method-header">
		<span class="method-title">getUserID</span> (line <span class="line-number">57</span>)
	</div> 
	
	<!-- ========== Info from phpDoc block ========= -->
<p class="short-description">Returns the user ID.</p>
	<ul class="tags">
				<li><span class="field">access:</span> public</li>
			</ul>
	
	<div class="method-signature">
		<span class="method-result">string</span>
		<span class="method-name">
			getUserID
		</span>
				()
			</div>
	
		
		
	</div>
<a name="methodremoveAttribute" id="removeAttribute"><!-- --></a>
<div class="evenrow">
	
	<div class="method-header">
		<span class="method-title">removeAttribute</span> (line <span class="line-number">94</span>)
	</div> 
	
	<!-- ========== Info from phpDoc block ========= -->
<p class="short-description">Removes an attribute from this <a href="../phpContentRepository/Credentials.html">Credentials</a> instance.</p>
	<ul class="tags">
				<li><span class="field">access:</span> public</li>
			</ul>
	
	<div class="method-signature">
		<span class="method-result">void</span>
		<span class="method-name">
			removeAttribute
		</span>
					(<span class="var-type">string</span>&nbsp;<span class="var-name">$name</span>)
			</div>
	
			<ul class="parameters">
					<li>
				<span class="var-type">string</span>
				<span class="var-name">$name</span><span class="var-description">: Specifies the name of the attribute to remove</span>			</li>
				</ul>
		
		
	</div>
<a name="methodsetAttribute" id="setAttribute"><!-- --></a>
<div class="oddrow">
	
	<div class="method-header">
		<span class="method-title">setAttribute</span> (line <span class="line-number">85</span>)
	</div> 
	
	<!-- ========== Info from phpDoc block ========= -->
<p class="short-description">Stores an attribute in this <a href="../phpContentRepository/Credentials.html">Credentials</a> instance.</p>
<p class="description"><p><strong>PHP Note</strong>: The Java implementation requires an object for  $value.  Since PHP is a loosely-typed language, it wouldn't  make sense to only allow a specific type of value so $value  can be any particular type.</p></p>
	<ul class="tags">
				<li><span class="field">access:</span> public</li>
			</ul>
	
	<div class="method-signature">
		<span class="method-result">void</span>
		<span class="method-name">
			setAttribute
		</span>
					(<span class="var-type">string</span>&nbsp;<span class="var-name">$name</span>, <span class="var-type">mixed</span>&nbsp;<span class="var-name">$value</span>)
			</div>
	
			<ul class="parameters">
					<li>
				<span class="var-type">string</span>
				<span class="var-name">$name</span><span class="var-description">: Specifies the name of the attribute to set</span>			</li>
					<li>
				<span class="var-type">mixed</span>
				<span class="var-name">$value</span><span class="var-description">: The value to be stored</span>			</li>
				</ul>
		
		
	</div>
						
		</div>
	</div>


	<p class="notes" id="credit">
		Documentation generated on Fri, 31 Dec 2004 10:15:09 -0600 by <a href="http://www.phpdoc.org" target="_blank">phpDocumentor 1.3.0RC3</a>
	</p>
	</div></body>
</html>